package com.kiryaka.images.icon
{
	public class IconManager
	{
		[Embed(source="assets/folder.png")] 
		public var folder:Class;
		
		[Embed(source="assets/document.png")] 
		public var document:Class;
		
		[Embed(source="assets/document-php.png")] 
		public var document_php:Class;

		[Embed(source="assets/document-text.png")] 
		public var document_text:Class;
		
		[Embed(source="assets/document-image.png")] 
		public var document_image:Class;		
		
		[Embed(source="assets/document-flash.png")] 
		public var document_flash:Class;
		
		[Embed(source="assets/document-code.png")] 
		public var document_code:Class;		
		
		[Embed(source="assets/parent.png")] 
		public var parent:Class;		
		
		public function IconManager()
		{
		}
		
		public function getSmallIconByType(type:String):Class{
			switch (type){
				case "gif" : return document_image; break;
				case "jpg" : return document_image; break;
				case "png" : return document_image; break;				
				case "parent" : return parent; break;
				case "file" : return document; break;
				case "dir" : return folder; break;
				
				case "php" : return document_php; break;
				case "txt" : return document_text; break;
				case "jpeg" : return document_image; break;
				case "swf" : return document_flash; break;
				case "c" : return document_code; break;
				case "asp" : return document_code; break;
				case "java" : return document_code; break;
				case "pl" : return document_code; break;
				case "sh" : return document_code; break;
			}
			return document;
		}
	}
}